package view;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JButton;
import javax.swing.JFrame;

public class ListarClientes extends javax.swing.JFrame{

    private static final long serialVersionUID = 1L;
    private ListarClientes instancia;
    private JButton buttonCerrar;
    
    public ListarClientes(){
            super();
            initGUI();
            instancia = this;
    }
    
    private void initGUI() {
            
            this.setLayout(null);
            //Create and set up the window.
	    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
	
	    //Create and set up the content pane.
	    PanelTablaClientes newContentPane = new PanelTablaClientes();
	    newContentPane.setOpaque(true); //content panes must be opaque
	    this.setContentPane(newContentPane);
	
	    //Display the window.
	    this.setSize(500, 400);
	    this.setVisible(true);
	            
        buttonCerrar = new JButton();
        this.add(buttonCerrar);
        buttonCerrar.setText("Cerrar Listado");
        buttonCerrar.setBounds(162,330, 150, 21);
        buttonCerrar.addActionListener(new ActionListener() {
	        public void actionPerformed(ActionEvent evt)
	        {
	                instancia.dispose();
	        }
	    });
    }      
}